package com.feige.pojo;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 班级表
 * </p>
 *
 * @author feige
 * @since 2020-11-20
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="Clazz对象", description="班级表")
public class Clazz implements Serializable {

    private static final long serialVersionUID = -8546242863475570346L;

    @ApiModelProperty(value = "签到编号")
    @TableId(value = "id", type = IdType.ID_WORKER_STR)
    private String id;

    @NotBlank(message = "班级名称不能为空")
    @ApiModelProperty(value = "班级名称")
    private String name;

    @NotBlank(message = "班级负责人不能为空")
    @ApiModelProperty(value = "班级负责人")
    private String userId;

    @ApiModelProperty(value = "班级已可加入人数")
    private Integer joinCount;

    @ApiModelProperty(value = "班级邀请码")
    private String inventCode;

    @ApiModelProperty(value = "班级邀请二维码路径")
    private String inventQrCodePath;

    @ApiModelProperty(value = "班级最大可加入人数")
    private Integer maxJoinCount;

    @ApiModelProperty(value = "状态(1正常，0禁用)")
    private Integer status;

    @ApiModelProperty(value = "是否删除")
    @TableLogic
    private Integer isDelete;

    @ApiModelProperty(value = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    private Date gmtCreate;

    @ApiModelProperty(value = "修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date gmtModified;


}
